<template>
    <div class="mymonitor_tabs">
        <div class="tabs">
            <div :class="monitorState.activemonitortab == 0 ? 'active_mymonitor_tab' : ''" @click="monitorState.activemonitortab = 0">我的监控</div>
            <div :class="monitorState.activemonitortab == 1 ? 'active_mymonitor_tab' : ''" style="margin-left: 24px;" @click="monitorState.activemonitortab = 1">比赛关注</div>
        </div>
        <div>
            <img src="@/assets/monitor/add.png" @click.stop="monitorStore.addmonitor()" alt="">
        </div>
    </div>
</template>

<script setup>
const { monitorStore, monitorState } = inject('MonitorStore')
</script>

<style lang="scss" scoped>
.mymonitor_tabs {
    height: 40px;
    display: flex;
    align-items: center;
    border-bottom: 1px solid #ebebeb;
    justify-content: space-between;
    padding: 0 12px;

    .tabs {
        display: flex;
        font-size: 14px;
        color: #000;
        height: 100%;

        div {
            cursor: pointer;
            border-bottom: 2px solid #fff;
            height: calc(100% - 2px);
            display: flex;
            align-items: center;
        }
    }
}

.active_mymonitor_tab {
    border-bottom: 2px solid #e92937 !important;
    color: #e92937;
    font-weight: 600;
}

img {
    width: 16px;
    height: 16px;
    cursor: pointer;
}
</style>